<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ include file="/common/taglibs.jsp"%>
<%@ include file="/common-app/taglibs.jsp"%>
<!DOCTYPE html>
<html>
<head>
<title>申请书编辑</title>
<c:if test="${empty param.include}">
	<%@ include file="/common/meta.jsp"%>
</c:if>
<style type="text/css">
.color_red{
	display:none;
}
#content{
    width:1040px;
}

</style>
<script type="text/javascript" src="${res}/js/proposal/irisPrpPrepare.js"></script>
<script type="text/javascript" src="${res_app}/js/app/proposal/irisPrpPrepare.js"></script>
<script type="text/javascript">

var ctxpath = "${ctx}";
var prcWin = new progressWin("${res}");//初始化遮罩层

$(function(){
	/* if("${param.viewAttach}"=="true")
		$("#tab9").click();
    if("${param.auditflag}"==""||"${param.auditflag}"==null)
		$("#tab2").click();
    if("${param.auditflag}"=="edit")
		$("#tab9").click(); */
	//updatePdfNotes();
	window.setInterval("checkPdfStatus()", "10000");//检验申请书的pdf
	refreshTextArea();
	resetTitle();
	
	$("table.t_css").each(function(){
		$(this).find("tr").not($(".cbTable").find("tr")).each(function(index){
		if(index%2==0)
		$(this).removeClass("li_1").addClass("li_2");
		else
		$(this).removeClass("li_2").addClass("li_1");
		});
		}); 
	$("table").addClass("table01");
	$('div').find("[id^='checkbox_dyn_']").find("table").removeClass("table01");
});



$(document).ready(function() {
	/* $("#attach_seq3").parent().parent().hide();
	$("#attach_seq2").parent().parent().hide();
	var tech_type = $.trim($("#tech_type").text());
	if(tech_type == '05'){
		$("#attach_seq915").parent().parent().hide();
		$("#attach_seq916").parent().parent().hide();
		$("#attach_seq917").parent().parent().hide();
		$("#attach_seq921").parent().html("1");
		$("#attach_seq922").parent().html("2");
		$("#attach_seq923").parent().html("3");
	}else{
		$("#attach_seq921").parent().parent().hide();
		$("#attach_seq922").parent().parent().hide();
		$("#attach_seq923").parent().parent().hide();
		$("#attach_seq915").parent().html("1");
		$("#attach_seq916").parent().html("2");
		$("#attach_seq917").parent().html("3");
	}
	$("#attach_seq918").parent().html("4");
	$("#attach_seq919").parent().html("5");
	$("#attach_seq924").parent().html("6"); */
	
	$("#prpContent_upload >tbody").find("tr:gt(6)").hide();
	
	var prp_attach_arrays=new Array();
	var v_boolean=false;
	/* $("#table_award_fjmucl > tbody").find("input[id^='kxjsj_fjmu_value_']").each(function(){
		var v_boolean=false;
		
		if($(this).val()!=''){
			 for ( var i = 0; i < prp_attach_arrays.length; i++) {
				 if(prp_attach_arrays[i]==$(this).val()){
					 v_boolean=true;
					 break;
				 }
			 }
			
			 if(!v_boolean){
				 prp_attach_arrays.push($(this).val());
			 }
		}
	}); */
	
	prp_attach_arrays.sort();
/* 	var v_rownum=3;
	 for ( var i = 0; i < prp_attach_arrays.length; i++) {
		$("#attach_seq"+prp_attach_arrays[i]).parent().parent().show();
		$("#attach_seq"+prp_attach_arrays[i]).parent().html(v_rownum++);
	} */
	  

	
	
});
function showSimilarityInfo(obj,type){
	var name=$(obj).parents("tr").find("span[name$='knowledge_name']").text();
	if(type=='2'){
		name=$(obj).parents("tr").find("span[name$='paper_name']").text();
	}
	var posCode=$("#posCode").val();
	tb_show("查看相似知识产权情况","${ctx}/proposal/findSimilarityInfo?name=" + encodeURI(name)+"&type="+type+"&posCode="+posCode
			+ "&TB_iframe=true&height=460&width=824", false);
}
</script>
</head>
<body>
	<c:set var="xmlstr" value="${xmlData}" />
	<x:parse xml="${xmlstr}" var="xmlData" />
	<input type="hidden" id="childDiv" class="thickbox"/>
	<input type="hidden" id="filePath" value="${ctx}/file/ajax-filedownload?fileCode=" />
	<input type="hidden" id="menuId" value="${param.menuId}" />
	<div id="showMessage"></div>
	<div id="content">
		<div class="clear_h15"></div>
		<div class="word_box" id="mainDiv">
			<div class="bar_b">
				<security:authorize ifNotGranted="A_MENU_REVIEW_09"><c:if test="${not empty fbl.pdfViewUrl}"><a href="#" onclick="return genPdf('<iris:des3 code="${posCode}"/>','<iris:des3 code="${fbl.pdfCode}"/>');" class="yase ico_pdf">查看pdf</a></c:if></security:authorize>
				<input type="hidden" id="pdfStatus" value="${pdfStatus}" />
				<span class="right">版本号：<span name="proposal/prp_version" id="prp_version"><x:out select="$xmlData/data/proposal/prp_version" /></span></span>
			</div>
			<form method="post" id="mainForm">
				<input type="hidden" value="${grantCode}" id="grantCode"
					name="grantCode"> 
				<input type="hidden" value="${posCode}" id="posCode" name="posCode"> 
				<input type="hidden" value="${xmlData}" id="xmlData" name="xmlData">
				<input type="hidden" value="${fbl.pdfCode}" id="pdfCode" name="pdfCode"> 
			</form>
				<div class="word_title">
					<c:set var="statYear">${statYear}</c:set>
					<c:if test="${empty statYear}">
						<c:set var="statYear"><x:out select="$xmlData/data/proposal/stat_year" /></c:set>
					</c:if>
					<input type="hidden" name="proposal/stat_year" value="${statYear}">
					<span name="proposal/grant_name" ><x:out select="$xmlData/data/proposal/grant_name" /></span>-推荐书 (<span name="proposal/show_stat_year">${year}</span>年)<br />					
					<input type="hidden" name="proposal/sub_grant_name" value="<x:out select="$xmlData/data/proposal/sub_grant_name" />" />
					<input type="hidden" name="proposal/grant_code" value="<x:out select="$xmlData/data/proposal/grant_code" />" />
					<input type="hidden" id="grant_no" name="proposal/grant_no" value="<x:out select="$xmlData/data/proposal/grant_no" />" />							
					<input type="hidden" name="proposal/sub_grant_code" value="<x:out select="$xmlData/data/proposal/sub_grant_code" />" />
					<input type="hidden" id="sub_grant_no" name="proposal/sub_grant_no" value="<x:out select="$xmlData/data/proposal/sub_grant_no" />" />
					<input type="hidden" name="proposal/help_grant_code" value="<x:out select="$xmlData/data/proposal/help_grant_code" />" />
					<input type="hidden" id="help_grant_no" name="proposal/help_grant_no" value="<x:out select="$xmlData/data/proposal/help_grant_no" />" />
					<c:set var="formCode"><x:out select="$xmlData/data/proposal/form_code" /></c:set>
					<c:if test="${empty formCode}"><c:set var="formCode" value="${param.formCode}"></c:set></c:if>
					<input type="hidden" name="proposal/form_code" value="${formCode}" />
				</div>
				
				
				<div id="tabnav">
					<ul>
						<!-- <li id="tab1" onclick="changeTab(this.id)">
						    <a href="###"><span>填写说明</span></a>
						</li> -->
						<li  class="down" id="tab1" onclick="changeTab(this.id)">
						    <a href="###"><span>项目基本情况</span></a>
						</li>
						<li  id="tab2" onclick="changeTab(this.id)">
						    <a href="###"><span>项目简介</span></a>
						</li>
						<li  id="tab3" onclick="changeTab(this.id)">
						    <a href="###"><span>项目详细内容</span></a>
						</li>
						
						<li id="tab4" onclick="changeTab(this.id)">
						    <a href="###"><span>主要论文专著目录</span></a>
						</li>
						
						<li id="tab5" onclick="changeTab(this.id)" >
						    <a href="###"><span>主要知识产权证明目录</span></a>
						</li>
	
						<li  id="tab6" onclick="changeTab(this.id)">
						   
						    
						    <c:set var="tech_type"><x:out select="$xmlData/data/proposal/tech_type_value" /></c:set>
						    <c:choose>
						     <c:when test="${tech_type eq '05'}">
						            <a href="###"><span>主要论文专著他引情况及科学意义和价值</span></a>
						     </c:when>
						     <c:otherwise>
						         <a href="###"><span>应用情况及效益</span></a>
						     </c:otherwise>
						    </c:choose>
						    
						</li>
						
						
						
					</ul>
				</div>
				<div id="tabnav">
					<ul>
						
						
						
						<li id="tab7" onclick="changeTab(this.id)" >
						    <a href="###"><span>客观评价</span></a>
						</li>
					
						
						<li id="tab8" onclick="changeTab(this.id)" >
						    <a href="###"><span>主要完成人</span></a>
						</li>
						
			
						<li id="tab9" onclick="changeTab(this.id)" >
						    <a href="###"><span>主要完成单位</span></a>
						</li>	
						
						
						
					<c:set var="recommend_type_value"><x:out select="$xmlData/data/proposal/recommend_type_value" /></c:set>
				   <c:if test="${recommend_type_value eq '02' }">
					  <li id="tab10" onclick="changeTab(this.id)" >
						    <a href="###"><span>推荐专家意见</span></a>
						</li>
					</c:if>
				
						
						<li id="tab11" onclick="changeTab(this.id)" >
						    <a href="###"><span>其他统计信息</span></a>
						</li>	
					
						
						<li id="tab12" onclick="changeTab(this.id)" >
						    <a href="###"><span>附件清单</span></a>
						</li>
					</ul>
				</div>
				
			
				<%-- <div class="tab_box" id="fragment-tab1">
					<jsp:include page="../instruction/prpEditGuide_kxjsjtjs.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
						<jsp:param value="${grantName}" name="grantName" />
					</jsp:include>
				</div> --%>
				
				
				<div class="tab_box" id="fragment-tab1">
					<jsp:include page="../info/prpInfoEdit_kxjstjs_2016.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
						<jsp:param value="${grantName}" name="grantName" />
					</jsp:include>
				</div>
				<div class="tab_box" id="fragment-tab2" style="display: none">
					<jsp:include page="../content/prpgoaledit_kxjstjs2.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div>
				<div class="tab_box" id="fragment-tab3" style="display: none">
					<jsp:include page="../content/prpgoaledit_kxjstjs_2016.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div>
				
				
				
				<div class="tab_box" id="fragment-tab4" style="display: none">
					<jsp:include page="../content/prpgoaledit_kxjstjs_paper_2016.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div>
				
				
				<div class="tab_box" id="fragment-tab5" style="display: none">
					<jsp:include page="../content/prpgoaledit_kxjstjs_knowledge_2016.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div> 
			
				
			  <div class="tab_box" id="fragment-tab6" style="display: none">
					<jsp:include page="../content/prpgoaledit_kxjstjs_award.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div>
				
				
				<div class="tab_box" id="fragment-tab7" style="display: none">
					<jsp:include page="../content/prpgoaledit_kxjstjs3fpj_2016.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div>
	
				<div class="tab_box" id="fragment-tab8" style="display: none">
					<jsp:include page="../psn/prpzhpsn_kxjsjtjs_zywcr_2016.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div>

				<div class="tab_box" id="fragment-tab9" style="display: none">
					<jsp:include page="../org/prpOrgEdit_kxjstjs_2016.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div>
				
				
					<div class="tab_box" id="fragment-tab10" style="display: none">
					<jsp:include page="../content/prpContentEdit_public.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
						<jsp:param value="专家意见" name="fileName" />
					</jsp:include>
				</div>
				
				
				<div class="tab_box" id="fragment-tab11" style="display: none">
					<jsp:include page="../content/prpContentEdit_others_2016.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div>
				
				
				
				
			<%-- 	<div class="tab_box" id="fragment-tab15" style="display: none">
					<jsp:include page="../content/prpContentEdit_kxjstsj_2016.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div>
				 --%>
				
				<%-- <div class="tab_box" id="fragment-tab14" style="display: none">
					<jsp:include page="../content/prpgoaledit_kxjstjs_award_fjmucl.jsp">  
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div> --%>
				<div class="tab_box" id="fragment-tab12" style="display: none">
					<jsp:include page="../attach/prpAttachEdit_common.jsp">
						<jsp:param value="${xmlstr}" name="xmlstr" />
					</jsp:include>
				</div> 
				
	</div>
	<div class="clear_h15"></div>
	</div>
</body>
</html>